
if __name__=="__main__":
    #ugly number
    k=1#起点
    c=0#统计个数
    while c<1500:
        s=k#保存一下k
        while s%2==0:
            s//=2
        while s % 3 == 0:
            s //= 3
        while s % 5 == 0:
            s //= 5

        if s==1:
            print(k,end=" ")
            c+=1
            if c%10==0:
                print()
        k+=1
    # h=10
    # count=0
    # trace=0
    # while h>=0.01:
    #     trace+=h
    #     count+=1
    #     h*=0.8
    #     trace+=h
    # print(f"经过{count}次，小球谈起的高度小于0.01,轨迹是{trace}米")